<template>
  <!-- 分页 -->
  <el-pagination
    :currentPage="pagingInfo.currentPage"
    :total="pagingInfo.total"
    :page-size="pagingInfo.page_size"
    :page-sizes="[1, 15, 30, 50, 80, 100]"
    layout="total, sizes, prev, pager, next, jumper"
    @size-change="size_current_change($event, 'size')"
    @current-change="size_current_change($event, 'current')"
  ></el-pagination>
</template>

<script>
export default {
  name: 'pagination',

  props: {
    pagingInfo: {
      type: Object,
      default: () => ({}),
    },
  },

  methods: {
    size_current_change(val, type) {
      this.$emit('size_current_change', { val, type })
    },
  },
}
</script>
